<template>
  <div>
    <h1 v-if="error.statusCode === 404">Page Not Found</h1>
    <div v-else>
      <h1>An error occurred</h1>
      <span style="color: #e92443;">{{ error.message }}</span>
    </div>
    <NuxtLink to="/">Stay with Dapianzi</NuxtLink>
  </div>
</template>
<script>
export default {
  props: {
    error: {
      type: Object,
      default: null,
    },
  },
  layout: 'error',
}
</script>
